/* 
 * File:   Dimension2D.h
 * Author: josep
 *
 * Created on 25 / desembre / 2010, 10:47
 */

#ifndef DIMENSION2D_H
#define	DIMENSION2D_H

class c2DArea {
public:
    enum tInclusionType { EXTERN=0, INCLUDE_NORTH=1, INCLUDE_EAST=2,
                                    INCLUDE_SOUTH=4, INCLUDE_WEST=8};
    c2DArea();
    virtual ~c2DArea();
    void Init(float minX, float minY, float width, float height, float speedX, float speedY);
    void SetPos(float minX, float minY);
    int GetIntersectionType(c2DArea* Area);
    bool hasIncluded(int inclusionValue, int InclusionType);
    bool hasIncluded(c2DArea* Area, int InclusionType);
    int minPointX();
    int minPointY();
    int maxPointX();
    int maxPointY();
    float GetSpeedX() const;
    float GetSpeedY() const;
private:
    float iniPointX;
    float iniPointY;
    float width;
    float height;
    float speedX;
    float speedY;

};

#endif	/* DIMENSION2D_H */

